<?php
return array(
	'attributeLabels' => array(
		'related_id' => '关系id',
		'provider_id' => '供应商',
		'dealer_id' => '经销商'
	),
	'rules' => array(
		array('item_num, goods_id, item_price, provider_id', 'required'),
		array('item_num', 'numerical', 'integerOnly'=>true),
	),
	
	'relations' => array(
		'goods' => array(
			CActiveRecord::BELONGS_TO, 'Goods', 'goods_id'
		),
		'order' => array(CActiveRecord::BELONGS_TO, 'Order', 'order_id'),
		'provider' => array(CActiveRecord::BELONGS_TO, 'ProviderAccount', 'provider_id'),
		'dealer' => array(CActiveRecord::BELONGS_TO, 'DealerAccount', 'dealer_id')
	),
	
	'_import' => array(
		array('*', 'models.ActiveRecord//*'),
	),
);